<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Class template custom_time_zone_base</title>
<link rel="stylesheet" href="../../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="../../index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
<link rel="up" href="../../date_time/doxy.html#header.boost.date_time.local_time.custom_time_zone_hpp" title="Header &lt;boost/date_time/local_time/custom_time_zone.hpp&gt;">
<link rel="prev" href="../serialization/load_1_3_12_15_5_16_1_1_11.html" title="Function template load">
<link rel="next" href="operat_1_3_12_15_6_4_2_1_1.html" title="Function operator+">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../boost.png"></td>
<td align="center"><a href="../../../../index.html">Home</a></td>
<td align="center"><a href="../../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../serialization/load_1_3_12_15_5_16_1_1_11.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../date_time/doxy.html#header.boost.date_time.local_time.custom_time_zone_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="operat_1_3_12_15_6_4_2_1_1.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.local_time.custom_time_zone_base"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2><span class="refentrytitle">Class template custom_time_zone_base</span></h2>
<p>boost::local_time::custom_time_zone_base — A real time zone. </p>
</div>
<h2 class="refsynopsisdiv-title">Synopsis</h2>
<div class="refsynopsisdiv"><pre class="synopsis"><span class="comment">// In header: &lt;<a class="link" href="../../date_time/doxy.html#header.boost.date_time.local_time.custom_time_zone_hpp" title="Header &lt;boost/date_time/local_time/custom_time_zone.hpp&gt;">boost/date_time/local_time/custom_time_zone.hpp</a>&gt;

</span><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> CharT<span class="special">&gt;</span> 
<span class="keyword">class</span> <a class="link" href="custom_time_zone_base.html" title="Class template custom_time_zone_base">custom_time_zone_base</a> <span class="special">:</span>
  <span class="keyword">public</span> <span class="identifier">date_time</span><span class="special">::</span><span class="identifier">time_zone_base</span><span class="special">&lt;</span> <span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">ptime</span><span class="special">,</span> <span class="identifier">CharT</span> <span class="special">&gt;</span>
<span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
  <span class="comment">// types</span>
  <span class="keyword">typedef</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">time_duration</span>                      <a name="boost.local_time.custom_time_zone_base.time_duration_type"></a><span class="identifier">time_duration_type</span><span class="special">;</span>
  <span class="keyword">typedef</span> <span class="identifier">date_time</span><span class="special">::</span><span class="identifier">time_zone_base</span><span class="special">&lt;</span> <span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">ptime</span><span class="special">,</span> <span class="identifier">CharT</span> <span class="special">&gt;</span> <a name="boost.local_time.custom_time_zone_base.base_type"></a><span class="identifier">base_type</span><span class="special">;</span>         
  <span class="keyword">typedef</span> <span class="identifier">base_type</span><span class="special">::</span><span class="identifier">string_type</span>                                <a name="boost.local_time.custom_time_zone_base.string_type"></a><span class="identifier">string_type</span><span class="special">;</span>       
  <span class="keyword">typedef</span> <span class="identifier">base_type</span><span class="special">::</span><span class="identifier">stringstream_type</span>                          <a name="boost.local_time.custom_time_zone_base.stringstream_type"></a><span class="identifier">stringstream_type</span><span class="special">;</span> 
  <span class="keyword">typedef</span> <span class="identifier">date_time</span><span class="special">::</span><span class="identifier">time_zone_names_base</span><span class="special">&lt;</span> <span class="identifier">CharT</span> <span class="special">&gt;</span>              <a name="boost.local_time.custom_time_zone_base.time_zone_names"></a><span class="identifier">time_zone_names</span><span class="special">;</span>   
  <span class="keyword">typedef</span> <span class="identifier">CharT</span>                                                 <a name="boost.local_time.custom_time_zone_base.char_type"></a><span class="identifier">char_type</span><span class="special">;</span>         

  <span class="comment">// <a class="link" href="custom_time_zone_base.html#boost.local_time.custom_time_zone_baseconstruct-copy-destruct">construct/copy/destruct</a></span>
  <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_11-bb"><span class="identifier">custom_time_zone_base</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">time_zone_names</span> <span class="special">&amp;</span><span class="special">,</span> <span class="keyword">const</span> <span class="identifier">time_duration_type</span> <span class="special">&amp;</span><span class="special">,</span> 
                        <span class="keyword">const</span> <span class="identifier">dst_adjustment_offsets</span> <span class="special">&amp;</span><span class="special">,</span> 
                        <span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span><span class="special">&lt;</span> <span class="identifier">dst_calc_rule</span> <span class="special">&gt;</span><span class="special">)</span><span class="special">;</span>
  <span class="keyword">virtual</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_12-bb"><span class="special">~</span><span class="identifier">custom_time_zone_base</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>

  <span class="comment">// <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10-bb">public member functions</a></span>
  <span class="keyword">virtual</span> <span class="identifier">string_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_1-bb"><span class="identifier">dst_zone_abbrev</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">string_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_2-bb"><span class="identifier">std_zone_abbrev</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">string_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_3-bb"><span class="identifier">dst_zone_name</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">string_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_4-bb"><span class="identifier">std_zone_name</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="keyword">bool</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_5-bb"><span class="identifier">has_dst</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">ptime</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_6-bb"><span class="identifier">dst_local_start_time</span></a><span class="special">(</span><span class="identifier">gregorian</span><span class="special">::</span><span class="identifier">greg_year</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">ptime</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_7-bb"><span class="identifier">dst_local_end_time</span></a><span class="special">(</span><span class="identifier">gregorian</span><span class="special">::</span><span class="identifier">greg_year</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">time_duration_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_8-bb"><span class="identifier">base_utc_offset</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">time_duration_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_9-bb"><span class="identifier">dst_offset</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
  <span class="keyword">virtual</span> <span class="identifier">string_type</span> <a class="link" href="custom_time_zone_base.html#id-1_3_12_15_6_3_1_1_1_10_10-bb"><span class="identifier">to_posix_string</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="special">}</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="id-1.3.12.15.6.3.3.4"></a><h2>Description</h2>
<div class="refsect2">
<a name="id-1.3.12.15.6.3.3.4.2"></a><h3>
<a name="boost.local_time.custom_time_zone_baseconstruct-copy-destruct"></a><code class="computeroutput">custom_time_zone_base</code> 
        public
       construct/copy/destruct</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem"><pre class="literallayout"><a name="id-1_3_12_15_6_3_1_1_1_11-bb"></a><span class="identifier">custom_time_zone_base</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">time_zone_names</span> <span class="special">&amp;</span> zone_names<span class="special">,</span> 
                      <span class="keyword">const</span> <span class="identifier">time_duration_type</span> <span class="special">&amp;</span> utc_offset<span class="special">,</span> 
                      <span class="keyword">const</span> <span class="identifier">dst_adjustment_offsets</span> <span class="special">&amp;</span> dst_shift<span class="special">,</span> 
                      <span class="identifier">boost</span><span class="special">::</span><span class="identifier">shared_ptr</span><span class="special">&lt;</span> <span class="identifier">dst_calc_rule</span> <span class="special">&gt;</span> calc_rule<span class="special">)</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">virtual</span> <a name="id-1_3_12_15_6_3_1_1_1_12-bb"></a><span class="special">~</span><span class="identifier">custom_time_zone_base</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre></li>
</ol></div>
</div>
<div class="refsect2">
<a name="id-1.3.12.15.6.3.3.4.3"></a><h3>
<a name="id-1_3_12_15_6_3_1_1_1_10-bb"></a><code class="computeroutput">custom_time_zone_base</code> public member functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem"><pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">string_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_1-bb"></a><span class="identifier">dst_zone_abbrev</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">string_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_2-bb"></a><span class="identifier">std_zone_abbrev</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">string_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_3-bb"></a><span class="identifier">dst_zone_name</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem"><pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">string_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_4-bb"></a><span class="identifier">std_zone_name</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre></li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">virtual</span> <span class="keyword">bool</span> <a name="id-1_3_12_15_6_3_1_1_1_10_5-bb"></a><span class="identifier">has_dst</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>True if zone uses daylight savings adjustments. </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">ptime</span> <a name="id-1_3_12_15_6_3_1_1_1_10_6-bb"></a><span class="identifier">dst_local_start_time</span><span class="special">(</span><span class="identifier">gregorian</span><span class="special">::</span><span class="identifier">greg_year</span> y<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Local time that DST starts – NADT if has_dst is false. </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">posix_time</span><span class="special">::</span><span class="identifier">ptime</span> <a name="id-1_3_12_15_6_3_1_1_1_10_7-bb"></a><span class="identifier">dst_local_end_time</span><span class="special">(</span><span class="identifier">gregorian</span><span class="special">::</span><span class="identifier">greg_year</span> y<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Local time that DST ends – NADT if has_dst is false. </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">time_duration_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_8-bb"></a><span class="identifier">base_utc_offset</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Base offset from UTC for zone (eg: -07:30:00) </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">time_duration_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_9-bb"></a><span class="identifier">dst_offset</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Adjustment forward or back made while DST is in effect. </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">virtual</span> <span class="identifier">string_type</span> <a name="id-1_3_12_15_6_3_1_1_1_10_10-bb"></a><span class="identifier">to_posix_string</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns a POSIX time_zone string for this object. </li>
</ol></div>
</div>
</div>
</div>
<div class="copyright-footer">Copyright © 2001-2005 CrystalClear Software, Inc<p>Subject to the Boost Software License, Version 1.0. (See accompanying file
    <code class="filename">LICENSE_1_0.txt</code> or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)</p>
</div>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../serialization/load_1_3_12_15_5_16_1_1_11.html"><img src="../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../date_time/doxy.html#header.boost.date_time.local_time.custom_time_zone_hpp"><img src="../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="operat_1_3_12_15_6_4_2_1_1.html"><img src="../../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>
